<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:zj="http://www.zju.edu.cn" exclude-result-prefixes="zj">
  <xsl:import href="../Tk2Base/GlobalVariable.xslt"/>
  <xsl:import href="ListFrame.xslt"/>
  <xsl:param name="Doc"/>
  <xsl:param name="IsPost" select="false()"/>
  <xsl:output method="html" indent="no"/>
  <xsl:template match="/">
    <xsl:choose>
      <xsl:when test="$IsPost">
        <xsl:call-template name="zj:SearchContent"/>
      </xsl:when>
      <xsl:otherwise>
        <html>
          <head>
            <title/>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
            <link rel="stylesheet" type="text/css" href="../css/style.css"/>
            <link rel="stylesheet" type="text/css" href="../themes/default/easyui.css"/>
            <link rel="stylesheet" type="text/css" href="../themes/icon.css"/>
            <script language="JavaScript" src="../js/jquery-1.7.1.min.js"></script>
            <script language="JavaScript" src="../js/jquery.easyui.min.js"></script>
            <script language="JavaScript" src="../js/common.js"></script>
            <xsl:call-template name="zj:PostScript"/>
          </head>
          <body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
            <div id="floatDiv" style="position: absolute; visibility: hidden; left:0px; top:0px; width:200px; height:200px; z-index:10; overflow: auto; border:solid 1px #003366; background-color: #FFFFEE" class="scrollBar"/>
            <table width="100%" height="100%" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td valign="top" id="contentTD">
                  <xsl:call-template name="zj:Content"/>
                </td>
              </tr>
            </table>
          </body>
        </html>
      </xsl:otherwise>
    </xsl:choose>
  </xsl:template>
  <xsl:template name="zj:Content">
    <table width="100%" border="0" cellspacing="0" cellpadding="6">
      <xsl:call-template name="zj:ListTitle"/>
      <tr>
        <td>
          <xsl:call-template name="zj:Search"/>
          <br/>
          <xsl:call-template name="zj:SearchContent"/>
        </td>
      </tr>
    </table>
  </xsl:template>
  <xsl:template name="zj:SearchContent">
    <table id="listDataGrid" width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td>
          <xsl:call-template name="zj:TabPage"/>
        </td>
      </tr>
      <tr id="td1">
        <td>
          <xsl:variable name="Page" select="$zj:Toolkit/Page"/>
          <xsl:apply-templates select="$Page"/>
          <xsl:if test="$Page/TotalPage > 1">
            <xsl:apply-templates select="$Page" mode="zj:Processbar"/>
          </xsl:if>

          <xsl:apply-templates select="$zj:XmlData/Toolkit/zj:Table" mode="zj:List"/>
          <xsl:apply-templates select="$Page"/>
        </td>
      </tr>
    </table>
  </xsl:template>
</xsl:stylesheet>
